package smartlifev30.com.sdk.bean.request;

import smartlifev30.com.sdk.net.baiwei.protocol.Body;

/**
 * Created by tys on 2018/8/15.
 */

public class ControlDeviceRequest extends Body {

    private Device  device;

    public Device getDevice() {
        return device;
    }

    public void setDevice(Device device) {
        this.device = device;
    }

    public class DeviceStatus {

        /**
         * DoorLock: 开门 仅支持on命令，off暂不支持
         * ZigbeeIO: on/off
         * 非可调灯,大功率模块:on/off
         * 可调灯:on/off
         * 窗帘: on/off/stop
         */
        private String state;

        /**
         * 可调灯:
         */
        private String color;

        /**
         * 单独控制灯光亮度的时候不要发送state  0 - 255
         * 可调灯:
         */
        private String level;


        /**
         * 温控器: off/cool/heat/auto/emergency/precool/fan_only/sleep/dry
         * off,sleep,dry模式后面不跟任何参数.
         */
        private String sys_mode;

        /**
         * 温控器:
         * 单位统一c
         */
        private int coolpoint;

        /**
         * 温控器:
         */
        private int heatpoint;

        /**
         * 温控器:
         */
        private int temp;

        /**
         * 温控器: off/low/medium/high/on/auto/smart
         * 风速
         */
        private String fan_mode;

        /**
         * 红外类设备:
         */
        private String name;

        /**
         * 红外类设备:
         * 用设备ID来表示
         */
        private int index;

        /**
         * 数据透传类设备/背景音乐
         */
        private String cmd;

        public String getState() {
            return state;
        }

        public void setState(String state) {
            this.state = state;
        }

        public String getColor() {
            return color;
        }

        public void setColor(String color) {
            this.color = color;
        }

        public String getLevel() {
            return level;
        }

        public void setLevel(String level) {
            this.level = level;
        }

        public String getSys_mode() {
            return sys_mode;
        }

        public void setSys_mode(String sys_mode) {
            this.sys_mode = sys_mode;
        }

        public int getCoolpoint() {
            return coolpoint;
        }

        public void setCoolpoint(int coolpoint) {
            this.coolpoint = coolpoint;
        }

        public int getHeatpoint() {
            return heatpoint;
        }

        public void setHeatpoint(int heatpoint) {
            this.heatpoint = heatpoint;
        }

        public int getTemp() {
            return temp;
        }

        public void setTemp(int temp) {
            this.temp = temp;
        }

        public String getFan_mode() {
            return fan_mode;
        }

        public void setFan_mode(String fan_mode) {
            this.fan_mode = fan_mode;
        }

        public String getName() {
            return name;
        }

        public void setName(String name) {
            this.name = name;
        }

        public int getIndex() {
            return index;
        }

        public void setIndex(int index) {
            this.index = index;
        }

        public String getCmd() {
            return cmd;
        }

        public void setCmd(String cmd) {
            this.cmd = cmd;
        }
    }

    public class Device {
        private int device_id;
        private DeviceStatus device_status;

        public int getDevice_id() {
            return device_id;
        }

        public void setDevice_id(int device_id) {
            this.device_id = device_id;
        }

        public DeviceStatus getDevice_status() {
            return device_status;
        }

        public void setDevice_status(DeviceStatus device_status) {
            this.device_status = device_status;
        }
    }
}
